package com.plm.mqshequ.service.impl;

import com.plm.mqshequ.dao.RoleDao;
import com.plm.mqshequ.entity.Role;
import com.plm.mqshequ.service.RoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author Limi
 * @create 2019-01-15 12:05
 */
@Service
public class RoleServiceImpl implements RoleService {

    @Autowired
    private RoleDao roleDao;

    @Override
    public void add(Role role) {
        roleDao.add(role);
    }

    @Override
    public void delete(Role role) {
        roleDao.delete(role);
    }

    @Override
    public void updateById(Role role) {
        roleDao.updateById(role);
    }

    @Override
    public List<Role> query() {
        return roleDao.query();
    }

    @Override
    public Role queryById(String id) {
        return roleDao.queryById(id);
    }

    @Override
    public Role queryByRole(String role) {
        return roleDao.queryByRole(role);
    }

    @Override
    public Role queryByUId(String uid) {
        return roleDao.queryByUId(uid);
    }
}
